<extend name="Base/common"/>

<block name="style">
    <link href="__CSS__/convert.css" rel="stylesheet" type="text/css"/>
</block>
<block name="header">
    <include file="Public/_nav"/>
</block>
<block name="body">

    <div class="alert alert-info with-icon">
        <i class="icon-info-sign"></i>

        <div class="content">以下为模块的转移，部分模块使用新版本安装，不需要转移。这里不一一列出。 选择需要的模块进行转移。<span style="color: red">转移前请先<a target="_blank" class="alert-link"
                                                                                                    href="{:U('admin/module/lists')}">安装</a>模块</span>
        </div>
    </div>
    <include file="Public/_info"/>


    <div class="message col-md-12">
        <ul class="clearfix" id="default_table" style="font-size: 14px;font-weight: bold">

            <volist name="table_list" key="key" id="table">
                <php>
                    if($data[$table['name']]['is_success']){
                    $class = 'show_success_'.$data[$table['name']]['is_success'] ;
                    $info= $data[$table['name']]['info'];
                    }elseif($data[$table['name']]['is_success'] ===0){
                    $class = 'show_error';
                    $info= $data[$table['name']]['info'];
                    }else{
                    $class = '';
                    $info= '等待转移。';
                    }
                </php>

                <php>if($table['name'] !== 0){</php>
                <li id="{$table.name}" class="{$class}" style="width: 60%;display: inline-block">
                    {:C("DB_PREFIX")}{$table['new_name']?$table['new_name']:$table['name']}

                    <span class="pull-right">{$info}</span>
                </li>
                <div class="operation" style="display: inline-block">
                    <a class="btn-xs btn" data-role="convert" data-table="{$table.name}"
                       data-single="1">点击单个转移</a>
                    <a class="btn-xs btn" data-role="convert" data-table="{$table.name}" data-single="0">点击转移以下全部</a>
                </div>
                <php>}else{</php>

                <hr>

           <h3>
               {$table.info}
               <div style="display: inline-block">
                   <a class="btn btn-primary" data-role="convert" data-table="{$table.next}" data-single="0">点击进行转移</a>
               </div>
            </h3>



                <php>}</php>
            </volist>
        </ul>

        <div id="finish" style="width: 50%;font-size: 18px;"><span class="pull-right"></span></div>

        <a class="btn btn-primary" href="{:U('Convert/addon/convert')}">上一步</a>
        <a class="btn btn-primary" href="{:U('Convert/base/finishConvert')}">完成</a>
    </div>


</block>
<block name="script">

    <script src="__JS__/convert.js"></script>
</block>

